from Algorithm.AlgorithmModel import ControlResult, ControlMode

class BaseServo():
    def __init__(self,ControlMode):
        self.mode=ControlMode
        self.__defControlMode()

    def __defControlMode(self):
        self.result = dict()
        self.lookahead_time = 0.03
        self.gain = 2000
        self.result['ControlResult'] = ControlResult.Stop
        self.result['ControlMode'] = self.mode
        self.result['ServoParm'] = [[0, 0, 0, 0, 0, 0], self.lookahead_time, self.gain]
        print("init servo para",self.result)